home *** CD-ROM | disk | FTP | other *** search
- package test.framework;
-
- public class TestFailure {
- protected Test fFailedTest;
- protected Throwable fThrownException;
-
- public TestFailure(Test failedTest, Throwable thrownException) {
- this.fFailedTest = failedTest;
- this.fThrownException = thrownException;
- }
-
- public Test failedTest() {
- return this.fFailedTest;
- }
-
- public Throwable thrownException() {
- return this.fThrownException;
- }
-
- public String toString() {
- StringBuffer buffer = new StringBuffer();
- buffer.append(this.fFailedTest + ": " + this.fThrownException.getMessage());
- return buffer.toString();
- }
- }
-